import { useState } from 'react';

export type ForceUpdate = () => void;

export default function useForceUpdate(): ForceUpdate {
  const [num, setNum] = useState(1);
  return () => {
    setNum((n) => n + 1);
  };
}
